package Bit排序算法;

/**
 * @author zx
 * @create 2022-03-16 20:46
 */
public class SortTest {
    public static void main(String[] args) {
        int n = 50000;
//        int[] arr = SortHelper.generateRandomArray(n,0,10);//生成范围内的重复数据
        int[] arr = SortHelper.generateRandomArray(n,0,Integer.MAX_VALUE);//生成的数据随机且范围大
        int[] arrCopy1 = SortHelper.arrCopy(arr);
        int[] arrCopy2 = SortHelper.arrCopy(arr);
        int[] arrCopy3 = SortHelper.arrCopy(arr);
        int[] arrCopy4 = SortHelper.arrCopy(arr);
        int[] arrCopy5 = SortHelper.arrCopy(arr);
        int[] arrCopy6 = SortHelper.arrCopy(arr);
        int[] arrCopy7 = SortHelper.arrCopy(arr);
        int[] arrCopy8 = SortHelper.arrCopy(arr);
        SortHelper.testSort("quickSort",arr);
        SortHelper.testSort("quickSort2",arrCopy1);
        SortHelper.testSort("quickSort3",arrCopy2);
        SortHelper.testSort("heapSort",arrCopy4);
        SortHelper.testSort("shellSort",arrCopy5);
        SortHelper.testSort("mergeSort",arrCopy6);
        SortHelper.testSort("insertionSort",arrCopy7);
        SortHelper.testSort("bubbleSort",arrCopy8);
    }
}
